/**
 * author:Administrator
 * date:2016/1/6
 * desc:TODO
 */

'use strict';

var Model = require('../model/WareSnapshot.js');
var Sequelize = require('sequelize');
var sequelize = require('../conn/sequelize.js');

let CommonDao = require('./_commonDao.js');
class TheDao extends CommonDao {
  constructor() {
    super(Model);
  }

  * findByWare(wareInfo) {
    let wareId = wareInfo.wareId;
    let ver = wareInfo.ver;
    return yield this.findOne({wareId: wareId, ver: ver});
  }

}
module.exports = new TheDao();
